package it.multisystem.geometry;

public class Rectangle extends Polygon {
	private double width;
	private double height;
	public Rectangle(String name, double width, double height) {
		super(name);
		this.width = width;
		this.height = height;
	}

	@Override
	public double area() {
		return this.width * this.height;
	}

	@Override
	public double perimeter() {
		return (this.width + this.height) * 2;
	}
}
